1. Field of the Invention
The present invention relates to machine vision systems and, more specifically, to performing multi-image training for pattern recognition and registration for machine vision systems.
2. Background Information
The use of advanced machine vision systems and their underlying software is increasingly employed in a variety of manufacturing and quality control processes. Machine vision enables quicker, more accurate and repeatable results to be obtained in the production of both mass-produced and custom products. Basic machine vision systems include one or more cameras (typically having solid-state charge couple device (CCD) imaging elements) directed at an area of interest, frame grabber/image processing elements that capture and transmit CCD images, a computer and display for running the machine vision software application and manipulating the captured images, and appropriate illumination on the area of interest.
Many applications of machine vision involve the inspection of components and surfaces for defects that affect quality. Where sufficiently serious defects are noted, a part of a surface is marked as unacceptable/defective. Machine vision has also been employed in varying degrees to assist in manipulating manufacturing engines in the performance of specific tasks.
The advent of increasingly faster and higher-performance computers, has enabled the development of machine vision systems that employ powerful search tools. In general, advanced machine vision tools acquire an image of a pattern via a camera and analyze the outline or a particular part of the pattern, such as a predetermined fiducial mark. The processing speed of the underlying computer in which the tool resides is sufficient to enable a very large number of real time calculations to be completed in a short time frame. This particularly enables the search tool to determine the coordinates within an image reference system for each analyzed point in the viewed area, and correlate these through repetition with a desired pattern. The search tool may map the locations of various points in the captured image to stored points in the model image, and determine whether the captured image points fall within an acceptable range of values relative to the model image points. Using various decision algorithms, the tool decides whether the viewed pattern, in a particular rotation and scale corresponds to the desired search pattern. If so, the tool confirms that the viewed pattern is, in fact, the pattern for which the tool is searching and fixes its position and orientation.
An example of such a search tool is the PatMax® product available from Cognex Corporation of Natick, Mass. One noted disadvantage of certain machine vision tools is that they perform training operations from a single training image. As industrial processes often exhibit a high degree of variability, choosing a single training image will bias the pattern and/or model towards the variations that appear in the single training image. Variations may include, for example, changes in lighting conditions and/or direction of light sources, small changes in perspective (“plane wobble”), background noise, rotation and/or translation of features within the image, etc. As noted, by utilizing a single training image, any of these variables that are included in the training image may cause a bias in the pattern utilized by the machine vision tool for identifying features during run time. For example, should the single training image include a poor representation of one feature, the trained model would incorporate a bias towards images that include similar poor representations of that feature. This may result in false negatives, i.e., decisions by the machine vision system that a feature is not present when, in fact, it is present in an image.
One approach to avoid the noted disadvantages of using single image training is to utilize a plurality of training images and to perform image averaging to generate an averaged training image. In such systems, a plurality of images is taken and an average of each pixel is calculated to generate the averaged training image. A noted disadvantage of such averaging techniques is that edges within the averaged training image may be blurred by the averaging operation. Additionally, erroneous features within the image that only appear in certain images may not be fully removed. For example, if an image contains a very bright erroneous feature in a first training image and not in a second training image, the average training image will contain a medium brightness feature. However, this feature is still erroneous as compared to the desired training image. Additionally, performing the averaging of the training images necessitates extremely precise alignment of the individual images in the average.
More generally, prior art techniques for registering a pattern often provide incorrect registration of consistent features, i.e., features that appear consistently in all images taken of a particular view. This may be due to variations in location of the feature, changes in lighting conditions, etc. What is needed is a technique to enable the training of a machine vision system to detect consistent features under high degrees of variability.